package com.gitee.genezhao.bean;

import lombok.SneakyThrows;

import java.io.UnsupportedEncodingException;

/**
 * Description:
 *
 * @Author: genezhao
 * @Date: 2018-05-28
 */
public class SneakyThrowsExample implements Runnable{

    @SneakyThrows(UnsupportedEncodingException.class)
    public String utf8ToString(byte[] bytes) {
        return new String(bytes, "UTF-8");
    }

    @SneakyThrows
    @Override
    public void run() {
        throw new Throwable();
    }
}
